package bookExercise;

import java.util.ArrayList;
import java.util.List;

public class A14Emplyee {
    private String name;
    private int age;
    private double salary;
    private String sex;
    private String dept;
    public A14Emplyee(){}
    public A14Emplyee(String name,int age,double salary,String sex,String dept){
        this.name=name;
        this.age=age;
        this.salary=salary;
        this.sex=sex;
        this.dept=dept;
    }
    public String getName(){
        return name;
    }
    public int getAge(){
        return age;
    }
    public double getSalary(){
        return salary;
    }
    public String getSex(){
        return sex;
    }
    public String getDept(){
        return dept;
    }
    public void setName(String name){
        this.name=name;
    }
    public void setAge(int age){
        this.age=age;
    }
    public void setSalary(double salary){
        this.salary=salary;
    }
    public void setSex(String sex){
        this.sex=sex;
    }
    public void setDept(String dept){
        this.dept=dept;
    }
    public String toString() {
        return "姓名：" + name + " 年龄：" + age + " 工资：" + salary + " 性别：" + sex + " 部门：" + dept;
    }
    public static List<A14Emplyee> getEmpList(){
        List<A14Emplyee> s =new ArrayList<>();
        s.add(new A14Emplyee("张强",31,12000,"男","开发部"));
        s.add(new A14Emplyee("李楠",29,11000,"男","开发部"));
        s.add(new A14Emplyee("苏玉",21,8000,"女","宣传部"));
        s.add(new A14Emplyee("宁镜",22,6500,"女","人事部"));
        s.add(new A14Emplyee("项楠竹",25,11000,"男","开发部"));
        s.add(new A14Emplyee("王甜",22,6000,"女","人事部"));
        s.add(new A14Emplyee("李建国",35,13000,"男","销售部"));
        return s;
    }
}
